/**
* 创建人：王曙光
* 创建时间：2011-9-20
* 功能描述：LocalStorage部分操作封装
*/
var UStoreConst = {
    home: 0,
    hash: {},
    filter: {
        type: "",
        list: ""
    }
};
var UStore = function() {
    return {
        usable: function() {
            if (window.localStorage)
                return true;
            else
                return false;
        },
        set: function(key, value) {
            window.localStorage.setItem(key, value);
        },
        get: function(key) {
            return window.localStorage.getItem(key);
        },
        clear: function() {
            window.localStorage.clear();
        },
        getLength: function() {
            return window.localStorage.length;
        },
        key: function(index) {
            return window.localStorage.key(index);
        },
        value: function(index) {
            return window.localStorage.getItem(window.localStorage.key(index));
        }
    }
} ();
